﻿using Protocol.Dto;

namespace Script.Model
{
    /// <summary>
    /// 游戏数据的存储类
    /// </summary>
    public class GameModel
    {
        /// <summary>
        /// 登录用户的数据
        /// </summary>
        public UserDto UserDto { get; set; }

        public int Id => UserDto.Id;

        public MatchRoomDto MatchRoomDto { get; set; }

        public UserDto GetUserDto(int userId)
        {
            return MatchRoomDto.UIdUserDict[userId];
        }

        public int GetRightUserId()
        {
            return MatchRoomDto.RightId;
        }
    }
}